﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using INSTA.BankApplication.Engine;
using NUnit.Framework;


namespace INSTA.BankApplication.Engine.Tests
{
    [TestFixture]
    public class Test_StandardAccount
    {
        AccountBase     _account;
        Customer        _holder;
        double          _amount;

        [SetUp]
        public void SetUp()
        {
            _amount = AccountFactory.MIN_DEPOSIT_STANDARD;   
            _holder     = new Customer();
            _account = Bank.Instance().CreateAccount(_holder, _amount);
        }


        [Test]
        public void Test_Method_GetMaxOverdrawn()
        {
            Assert.IsTrue(_account.GetMaxOverdrawn() == 10);

            
        }

        [Test]
        public void Test_Method_WithdrawMonthlyFees()
        {
            _account.WithdrawMonthlyFees();

            Assert.IsTrue(_account.Balance == _amount - 30);
        }



        
    }
}
